package 笔记.设计模式.策略模式;

/**
 * @author chenhailong
 * @ClassName: Context
 * @Description: TODO
 * @date 2021/7/1 21:51
 * @Version 1.0
 */
public class Context {

    private Strategy strategy;




   public Context(Strategy strategy) {
        this.strategy = strategy;
    }

    public int calculation(int a, int b) {
        int strategy = this.strategy.strategy(a, b);
        return strategy;
    }
}
